package file1;

import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.Scanner;

public class Test1 {
    public static void main(String[] args) {
        try (InputStream inputStream = new FileInputStream("test/test.txt")) {
            try (Scanner scanner = new Scanner(inputStream, "utf-8")) {
                while (scanner.hasNext()) {
                    String s = scanner.next();
                    System.out.println(s);
                }
            }
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }
}
